
#ifndef __EGG_LOADER_H
#define __EGG_LOADER_H

#include <iostream>
#include <string>


class Egg
{
/* Member Variables */
private:
	FILE *egg;
	float *vertices, *normals, *texCoords;
	int *indices;
	int numVertices, numNormals, numtexCoords, numTriangles;
	unsigned int startingAlloc;
	int* alloc;
	int animationAngle;
public:


/* Member Functions */
private:
	void parseVertexBlock(char *str);
	void parsePolygonBlock(char *str);
	void parseVertex(char *str);
	void parseNormal(char *str);
	void parseTexCoord(char *str);
	void Egg::doubleArrayAllocation(float*& ar, int size);
	void Egg::checkAllocation(float*& ar, int alloc, int num);

public:
	Egg( );
	Egg( std::string filename);
	void loadEgg(std::string filename);

	void draw();
};

#endif